package com.hzspace.xml;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author: LiuHao
 * @Descirption:
 * @Date: 2020/2/29_22:49
 */
@RestController
public class HelloController {

    //该类没有加@Service注解 是通过bean.xml注入 通过SpringBeanConfig配置扫描xml注解配置
    @Autowired
    HelloService helloService;

    @GetMapping("/hello")
    public Object sayHello(){
        return helloService.sayHello();
    }
}
